import { post } from './axios';

/**
 * 类型接口方法
 */

// 添加
export function addType (params) {
    return post('/system/type/add', params);
}

// 修改
export function editType (params) {
    return post('/system/type/edit', params);
}

// 删除
export function deleteType (params) {
    return post('/system/type/delete', params);
}

// 查询
export function searchType (params) {
    return post('/system/type/search', params);
}

/**
 * 配置接口方法
 */

// 查询

export function searchConfigure (params) {
    return post('/system/configure/search', params);
}

/**
 * 用户接口方法
 */

// 查询
export function searchUser (params) {
    return post('/system/user/search', params);
}

// 添加
export function addUser (params) {
    return post('/system/user/add', params);
}

// 删除
export function deleteUser (params) {
    return post('/system/user/delete', params);
}

// 修改
export function editUser (params) {
    return post('/system/user/edit', params);
}

/**
 * 文章接口方法
 */

// 查询
export function searchArticle (params) {
    return post('/system/article/search', params);
}

// 添加
export function addArticle (params) {
    return post('/system/article/add', params);
}

// 删除
export function deleteArticle (params) {
    return post('/system/article/delete', params);
}

// 修改
export function editArticle (params) {
    return post('/system/article/edit', params);
}

/**
 * 评论接口方法
 */

// 查询
export function searchComment (params) {
    return post('/system/comment/search', params);
}

// 删除
export function deleteComment (params) {
    return post('/system/comment/delete', params);
}

/**
 * 统计接口方法
 */

export function getStatistics (params) {
    return post('/system/statistics/getStatistics', params);
}

export function getArticleRanking (params) {
    return post('/system/statistics/getArticleRanking', params);
}
